Posted: Sat Dec 19, 2009 6:26 am Post subject: Routers with serial port inside WAN port
On some latest Linksys routers it is not necessary to open them (and loose warranty) to access serial console. It is inside WAN port.
As far as I know these routers have it:
- WRT150N v1.1
- WRT300N v1.1
- WRT310N v1
- WRT320N
- WRT610N v1
- WRT610N v2
If you know any other or you know of good way to make a connector for it, please tell us.
serial_in_wan.JPG
Description:
Filesize:
201.04 KB
Viewed:
18303 Time(s)
_________________ Professional debrick service for EU countries for small fee.
Send inquiries to: debrick at dd-wrt dot si
Have a brick you don't need?
Paypal & Amazon.com gift cards are welcome. Every $ or € counts. Email: donate at dd-wrt dot si
I was going to make one so took a RJ-45 connector, removed the lock piece and grinded the surface flat.
Remember the cardedge connector used for hard disks and floppy drives in the past?
I intended to take out 4 pins from one of them, cut the pins so they fit on the top of the RJ-45 , solder wires to them and then melt them into the the plastic or superglue them.
The project abruptly went to sleep when I realised that I don't have any of those cardedge connectors and no computer shops around here carried them. _________________ Sorry, I'm too lazy to google it for you! Consumer power - Say NO to 4MB flash routers.
Ah.. I wanted red marked cable to be +3.3, but I did it in reverse (mirror)... so be careful.... _________________ Professional debrick service for EU countries for small fee.
Send inquiries to: debrick at dd-wrt dot si
Have a brick you don't need?
Paypal & Amazon.com gift cards are welcome. Every $ or € counts. Email: donate at dd-wrt dot si
Joined: 30 Jun 2009 Posts: 845 Location: Camp Pendleton, CA
Posted: Sat Apr 10, 2010 4:01 pm Post subject:
I think I may have posted this in another thread...but I saw this one come back up so I wanted to reconfirm what I found out about 2 months ago.
Attached are pictures of the device...Landley says they had to use an Ethernet plug with the clip broken off to keep it in the port, and even then it was a pain in the ass.
Here's some text he included...probably elementary to a few of you guys.
--- Re-flashing a linksys router using the CFE bootloader.
-- What is the CFE bootloader?
CFE is Broadcom's "Common Firmware Environment". It's the bootloader installed
at the start of the flash on most Linksys routers, and it's the program that
takes control when the device is first turned on.
Linksys' image flashing procedures do not replace this bootloader. If the
web GUI isn't coming up after a firmware upgrade, we can use the bootloader
to install a known working firmware image and thus "unbrick" the device.
-- What do I need?
You will need:
linksys router.
serial adapter for your router model.
ethernet cable.
firmware image file.
Laptop/desktop system with:
working serial and ethernet ports.
firmware image file (from linksys.com)
serial term program (minicom)
tftp file transfer program (tftp)
You may need:
another ethernet cable
serial passthrough cable
serial gender changer
-- What do I do?
1) Set up the serial console.
A) Attach your serial adapter to your linksys router.
On the WRT610n, the serial adapter plugs into the bottom of the internet
uplink port, pins facing downwards, and is held in place by the ethernet
cable. (You may need a "broken" ethernet cable with the latching tab
removed to fit both in. If the result falls out too easily, masking tape
is easier to remove afterwards than duct tape.)
B) Connect your laptop to the linksys adapter's serial port.
USB->serial adapters are available for laptops without serial ports.
If you need a serial extension cable use a passthrough (not null-modem)
cable. You may need a serial gender changer to make the physical
connection.
C) Run a terminal program on your laptop configured for "115k 8n1"
operation.
This program will talk to the serial console on the router.
D) Power cycle the router and see if you get any boot messages.
If the bootloader has been overwritten, the device really is bricked and
you need a JTAG to restore it, but this is unlikely. None of Linksys'
image update procedures overwrite the bootloader.
2) Get a "CFE>" prompt.
Power cycle the device, and immediately send ctrl-c a few times over the
serial connection. This should interrupt the bootloader and give you a
"CFE>" prompt.
Type "help" at this prompt and hit ENTER for a list of available
commands.
3) Set up networking.
A) Connect your laptop to one of the router's switch ports with a standard
CAT 5 ethernet patch cable.
Don't connect your laptop to the "internet" port. You may need a cat5
cable in that port to hold the serial adapter in place, but that cable
isn't the one you connect to your laptop. (This is why you may need
a second ethernet cable.)
B) On the serial console, type "printenv" and hit ENTER. The variable
NET_IPADDR should default to "192.168.1.1".
C) Set your laptop's internet address for the ethernet adapter to
"192.168.1.2". For example, on Linux you may need to execute the
following command (as root):
ifconfig eth0 192.168.1.2
4) Send and save the firmware image file from your laptop to the router.
This is a three part process:
- The laptop must send the image file through the network via TFTP.
- CFE must read the image from the network into the router's memory.
- CFE must burn the image from the router's memory into flash.
The first two of these steps must occur near-simultaneously, TFTP tends
to have fairly short timeouts, so we set up the commands in two separate
windows and press "enter" in each window.
A) On your laptop, prepare a binary tftp file transfer command to send the
firmware image to 192.168.1.1, but don't press "enter" yet. For
example, to send WRT610n firmware from Ubuntu:
(echo binary ; echo put FW_WRT610N_*_code.bin) | tftp 192.168.1.1
B) In the terminal console window, type the CFE receive command for
the firmware image, but don't press "enter" yet:
load -tftp -raw -addr=0x807a60b0 -max=0x800000 :
(Don't forget the trailing colon, it's important.)
C) Press ENTER in the tftp window and the terminal console within 5
seconds of each other.
If it instead says timeout, set up the commands and try again.
D) Confirm the firmware file's size.
The "bytes read" value above should match the length of the firmware
file on the laptop. If it doesn't, then you probably did an ascii
transfer instead of binary, which won't work.
F) Tell CFE to burn the image from memory into the flash.
In the serial terminal window, at the "CFE>" prompt, type the following
flash command, using the "size" value of _your_ firmware, which is
probably NOT the one shown here. (Repeat, for -size use the "bytes
read" value above.)
Unplug it, plug it back in. If all went well, you should see lots of
Linux kernel boto messages scroll by as it comes up running the new
firmware image.
When a standard Linksys firmware image has finished booting, if you hit
ENTER on the serial console you should get a root shell prompt.
socal87, did you make that PCB that you posted pics of? Can you post some info on how/where you got that?
It's the device that a Cisco employee (contractor iirc?) received to use the serial connection in the WAN port. They are not publicly available.
I've added these models to the list:
WRT150N v1.1
WRT300N v1.1 _________________ If your build is older than a year then update if you want support. Broadcom recommended builds (Click this!)
Only use tested forum recommended builds (DB recommendations are bad) and read the forum announcements!
Advanced configuration help takes considerable time, stipend helps coax answers.
Looking for bricks and spare routers for testing/tutorials.
I like Eko's solution better than a PCB, it's cheap, easy to do, and won't break. _________________ If your build is older than a year then update if you want support. Broadcom recommended builds (Click this!)
Only use tested forum recommended builds (DB recommendations are bad) and read the forum announcements!
Advanced configuration help takes considerable time, stipend helps coax answers.
Looking for bricks and spare routers for testing/tutorials.
With Eko's cable, do we need any conversion or can we go straight to a serial port connector?
Thanks
It's TTL so you need a level shifter. You can get a cheap CA-42 or DKU-5 USB phone cable to do it. _________________ If your build is older than a year then update if you want support. Broadcom recommended builds (Click this!)
Only use tested forum recommended builds (DB recommendations are bad) and read the forum announcements!
Advanced configuration help takes considerable time, stipend helps coax answers.
Looking for bricks and spare routers for testing/tutorials.
How'd you strip that cable so nicely? This is proving to be quite a pain in the ass :(
EDIT: Did quite nicely with a nail file
For future reference, you can strip cables nicely by laying a thin knife flat against the cable and gently pressing it into the jacket while you run it down the cable.
WithinRafael wrote:
I'm getting just garbage on the E3000's Rx, tried various configurations of the line. I verified the cable is working by tying Rx/Tx together.
Would this be a symptom of the CFE being corrupted? Does DD-WRT overwrite this on flash (from stock firmware upload interface)?
Like BW said, what are you using as a cable and have you figured out what the other wires are? You need to be sure to connect the cable's TX to the router's RX and vice versa. Connect the ground to ground and Vcc to Vcc. I spazzed for a day when I first did it and had my ground going to Vcc and it wasn't until I noticed an occasional spark sound that I finally realized I had it wrong. _________________ If your build is older than a year then update if you want support. Broadcom recommended builds (Click this!)
Only use tested forum recommended builds (DB recommendations are bad) and read the forum announcements!
Advanced configuration help takes considerable time, stipend helps coax answers.
Looking for bricks and spare routers for testing/tutorials.
Thanks for the cable tip. This CA-42 cable simply has Rx, Tx, and Gnd. I should be able to simply touch my Rx w/ its Tx and see data... right? (It works in Avatar.) As the chip is receiving power from the USB port, I ignored the router's 3.3v.